package com.aidex.system.mapper;

import com.aidex.common.core.mapper.BaseMapper;
import com.aidex.system.domain.Waybill;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 运单管理Mapper接口
 * @author jmy
 * @email jmyinjg@163.com
 * @date 2021-10-04
 */
public interface WaybillMapper extends BaseMapper<Waybill> {

    /**
     * 批量删除运单管理
     * @param ids 需要删除的运单管理ID集合
     * @return
     */
    int deleteWaybillByIds(String[] ids);

    void deleteWaybillByBillno(@Param("waybillNo") String waybillNo);

    Waybill getByBillno(@Param("waybillNo") String waybillNo, @Param("dataSource") String dataSource);

    /**
     * 批量获取未处理的单据列表
     *
     * @param limit
     * @return
     */
    List<Waybill> getUnHandleBillList(@Param("limit") Integer limit);

    Waybill getUnSend(@Param("waybillNo")  String waybillNo);
}
